package com.msh.artascope.devcloud.service;

import com.alibaba.fastjson.parser.ParserConfig;
import com.msh.frame.client.interfaces.IClassLoadLog;
import com.msh.frame.client.util.StartupUtil;
import lombok.extern.slf4j.Slf4j;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ConfigurableApplicationContext;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.transaction.annotation.EnableTransactionManagement;

/**
 * @author shihu
 * @mail m-sh@qq.com
 */
@SpringBootApplication
@ComponentScan("com.msh.artascope.devcloud")
@MapperScan(basePackages = "com.msh.artascope.devcloud.service.dao")
@EnableTransactionManagement
@Slf4j
public class DevcloudServerApplication{
  public static void main(String[] args) {
    ParserConfig.getGlobalInstance().addAccept("com.msh.artascope.devcloud.");
    ConfigurableApplicationContext context = SpringApplication.run(DevcloudServerApplication.class, args);
    StartupUtil.printLoadClass(context.getBeansOfType(IClassLoadLog.class));
    StartupUtil.logApplicationStartup(context.getEnvironment());
  }
}
